import axios from 'axios'
const baseURL = 'http://43.138.15.137:7000/api/private/v1'
const token = localStorage.getItem('token')
export default () => ({
  methods: {
    // 修改后
    $httpGet(url, params) {
      return this.$axios.get(url, { 
        params, // 添加params参数
        headers: {
          Authorization: this.token // 使用组件中的token
        }
      })
    }
  }
})